package javabase.base.client09.p1;

/**
 * @author chengshuai
 * @date 2021/4/27 22:00
 */
public class Father implements Cloneable {

    protected void f1() {
        System.out.println("父类受保护方法");
    }

    public static void main(String[] args) {
        Father father1 = new Father();
        try {
            Father father2 = (Father) father1.clone();
            System.out.println(father1==father2);
            System.out.println(father1);
            System.out.println(father2);
        } catch (CloneNotSupportedException e) {
            e.printStackTrace();
        }
    }

}
